package com.cloudlead.commonData.vo;

import com.cloudlead.common.lang.persistence.AbstractIdEntity;

import com.cloudlead.commonData.action.validator.BaseVoyageValidatorGroup.*;

import javax.validation.constraints.Size;
import com.cloudlead.common.lang.annotation.BelongsTos;
import com.cloudlead.common.lang.annotation.Domain;
import org.joda.time.DateTime;
import com.cloudlead.common.lang.annotation.Label;
import java.lang.String;
import javax.validation.constraints.NotNull;
import com.cloudlead.commonData.vo.BaseCompany;
import com.cloudlead.commonData.vo.BaseShip;
import com.cloudlead.commonData.vo.BaseShipRoute;

/**
 * BaseVoyage is a Codegen vo type
 */
@Label("航次表")
@Domain(domainClassName="com.cloudlead.commonData.entity.EBaseVoyage")
@BelongsTos(values = {
	@com.cloudlead.common.lang.annotation.BelongsTo(property="baseCompany", rootField="baseCompanyId")
,	@com.cloudlead.common.lang.annotation.BelongsTo(property="baseShip", rootField="baseShipId")
,	@com.cloudlead.common.lang.annotation.BelongsTo(property="baseShipRou", rootField="baseShipRoute")
})
public class BaseVoyage extends AbstractIdEntity<String> {

    private static final long serialVersionUID =7277673590280L;    
    @Label("预计到港时间")
    private DateTime arriveExpectedTime;

    @Label("实际到港时间")
    private DateTime arriveTime;

    @NotNull(groups={Create.class,Update.class})
    @Label("baseCompanyId")
    private BaseCompany baseCompany;

    @NotNull(groups={Create.class,Update.class})
    @Label("baseShipId")
    private BaseShip baseShip;

    @Label("航线")
    private BaseShipRoute baseShipRou;

    @Label("删除标记")
    @Size(max=8)
    private String flag;

    @NotNull(groups={Update.class})
    @Label("ID")
    @Size(max=24)
    private String id;

    @Label("预计发船时间")
    private DateTime startExpectedTime;

    @Label("实际发船时间")
    private DateTime startTime;

    @Label("状态")
    @Size(max=45)
    private String state;

    @Label("船名")
    @Size(max=255)
    private String vessel;

    @Label("航次名")
    @Size(max=45)
    private String voyage;

    public DateTime getArriveExpectedTime() {
        return arriveExpectedTime;
    }

    public void setArriveExpectedTime(DateTime arriveExpectedTime) {
        this.arriveExpectedTime = arriveExpectedTime;
    }

    public DateTime getArriveTime() {
        return arriveTime;
    }

    public void setArriveTime(DateTime arriveTime) {
        this.arriveTime = arriveTime;
    }

    public BaseCompany getBaseCompany() {
        return baseCompany;
    }

    public void setBaseCompany(BaseCompany baseCompany) {
        this.baseCompany = baseCompany;
    }

    public BaseShip getBaseShip() {
        return baseShip;
    }

    public void setBaseShip(BaseShip baseShip) {
        this.baseShip = baseShip;
    }

    public BaseShipRoute getBaseShipRou() {
        return baseShipRou;
    }

    public void setBaseShipRou(BaseShipRoute baseShipRou) {
        this.baseShipRou = baseShipRou;
    }

    public String getFlag() {
        return flag;
    }

    public void setFlag(String flag) {
        this.flag = flag;
    }

    public String getId() {
        return id;
    }

    public void setId(String id) {
        this.id = id;
    }

    public DateTime getStartExpectedTime() {
        return startExpectedTime;
    }

    public void setStartExpectedTime(DateTime startExpectedTime) {
        this.startExpectedTime = startExpectedTime;
    }

    public DateTime getStartTime() {
        return startTime;
    }

    public void setStartTime(DateTime startTime) {
        this.startTime = startTime;
    }

    public String getState() {
        return state;
    }

    public void setState(String state) {
        this.state = state;
    }

    public String getVessel() {
        return vessel;
    }

    public void setVessel(String vessel) {
        this.vessel = vessel;
    }

    public String getVoyage() {
        return voyage;
    }

    public void setVoyage(String voyage) {
        this.voyage = voyage;
    }

    public String toString() {
         return String.format("BaseVoyage { arriveExpectedTime : %s,arriveTime : %s,baseCompany : %s,baseShip : %s,baseShipRou : %s,flag : %s,id : %s,startExpectedTime : %s,startTime : %s,state : %s,vessel : %s,voyage : %s }",arriveExpectedTime,arriveTime,baseCompany,baseShip,baseShipRou,flag,id,startExpectedTime,startTime,state,vessel,voyage);
    }

}

